MetNoFimex::Units Class Reference

#include <Units.h>

List of all members.

Public Member Functions

 Units ()
 Units (const Units &rhs)
Unitsoperator= (const Units &rhs)
virtual ~Units ()
void convert (const std::string &from, const std::string &to, double *slope, double *offset) throw (UnitException)
bool areConvertible (const std::string &unit1, const std::string &unit2) const throw (UnitException)
 test if two units are convertible to each others
bool isTime (const std::string &timeUnit) const throw (UnitException)


Constructor & Destructor Documentation

MetNoFimex::Units::Units  ) 
 

initialization of unit handling, i.e. parsing of unit file etc if required

MetNoFimex::Units::Units const Units rhs  ) 
 

virtual MetNoFimex::Units::~Units  )  [virtual]
 


Member Function Documentation

bool MetNoFimex::Units::areConvertible const std::string unit1,
const std::string unit2
const throw (UnitException)
 

test if two units are convertible to each others

Parameters:
unit1 first unit
unit2 second unit

void MetNoFimex::Units::convert const std::string from,
const std::string to,
double *  slope,
double *  offset
throw (UnitException)
 

calculate the linear unit conversion: newVal (in to unit) = oldVal (in from unit) * slope + offset

Parameters:
from unit
to unit
slope return value of the slope
offset return value of the offset

bool MetNoFimex::Units::isTime const std::string timeUnit  )  const throw (UnitException)
 

Units& MetNoFimex::Units::operator= const Units rhs  ) 
 


The documentation for this class was generated from the following file:
Generated on Thu Aug 7 08:50:02 2008 for MI - Fimex by  doxygen 1.4.6